/*
 * Selling Partner API for Messaging
 *
 * With the Messaging API you can build applications that send messages to buyers. You can get a list of message types that are available for an order that you specify, then call an operation that sends a message to the buyer for that order. The Messaging API returns responses that are formed according to the <a href=https://tools.ietf.org/html/draft-kelly-json-hal-08>JSON Hypertext Application Language</a> (HAL) standard.
 *
 * The version of the OpenAPI document: v1
 * Generated by: https://github.com/openapitools/openapi-generator.git
 */

using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using RestSharp;
using software.amzn.spapi.Client;
using software.amzn.spapi.Auth;

using software.amzn.spapi.Model.messaging.v1;

namespace software.amzn.spapi.Api.messaging.v1
{
    /// <summary>
    /// Represents a collection of functions to interact with the API endpoints
    /// </summary>
    public interface IMessagingApi : IApiAccessor
    {
        #region Synchronous Operations
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmCustomizationDetailsResponse</returns>
        CreateConfirmCustomizationDetailsResponse ConfirmCustomizationDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmCustomizationDetailsResponse</returns>
        ApiResponse<CreateConfirmCustomizationDetailsResponse> ConfirmCustomizationDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateAmazonMotorsResponse</returns>
        CreateAmazonMotorsResponse CreateAmazonMotors (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateAmazonMotorsResponse</returns>
        ApiResponse<CreateAmazonMotorsResponse> CreateAmazonMotorsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmDeliveryDetailsResponse</returns>
        CreateConfirmDeliveryDetailsResponse CreateConfirmDeliveryDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmDeliveryDetailsResponse</returns>
        ApiResponse<CreateConfirmDeliveryDetailsResponse> CreateConfirmDeliveryDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmOrderDetailsResponse</returns>
        CreateConfirmOrderDetailsResponse CreateConfirmOrderDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmOrderDetailsResponse</returns>
        ApiResponse<CreateConfirmOrderDetailsResponse> CreateConfirmOrderDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmServiceDetailsResponse</returns>
        CreateConfirmServiceDetailsResponse CreateConfirmServiceDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmServiceDetailsResponse</returns>
        ApiResponse<CreateConfirmServiceDetailsResponse> CreateConfirmServiceDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateDigitalAccessKeyResponse</returns>
        CreateDigitalAccessKeyResponse CreateDigitalAccessKey (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateDigitalAccessKeyResponse</returns>
        ApiResponse<CreateDigitalAccessKeyResponse> CreateDigitalAccessKeyWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateLegalDisclosureResponse</returns>
        CreateLegalDisclosureResponse CreateLegalDisclosure (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateLegalDisclosureResponse</returns>
        ApiResponse<CreateLegalDisclosureResponse> CreateLegalDisclosureWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateUnexpectedProblemResponse</returns>
        CreateUnexpectedProblemResponse CreateUnexpectedProblem (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateUnexpectedProblemResponse</returns>
        ApiResponse<CreateUnexpectedProblemResponse> CreateUnexpectedProblemWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateWarrantyResponse</returns>
        CreateWarrantyResponse CreateWarranty (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateWarrantyResponse</returns>
        ApiResponse<CreateWarrantyResponse> CreateWarrantyWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>GetAttributesResponse</returns>
        GetAttributesResponse GetAttributes (string amazonOrderId, List<string> marketplaceIds);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>ApiResponse of GetAttributesResponse</returns>
        ApiResponse<GetAttributesResponse> GetAttributesWithHttpInfo (string amazonOrderId, List<string> marketplaceIds);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>GetMessagingActionsForOrderResponse</returns>
        GetMessagingActionsForOrderResponse GetMessagingActionsForOrder (string amazonOrderId, List<string> marketplaceIds);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>ApiResponse of GetMessagingActionsForOrderResponse</returns>
        ApiResponse<GetMessagingActionsForOrderResponse> GetMessagingActionsForOrderWithHttpInfo (string amazonOrderId, List<string> marketplaceIds);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message providing the buyer an invoice
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>InvoiceResponse</returns>
        InvoiceResponse SendInvoice (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message providing the buyer an invoice
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of InvoiceResponse</returns>
        ApiResponse<InvoiceResponse> SendInvoiceWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body);
        #endregion Synchronous Operations
        #region Asynchronous Operations
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmCustomizationDetailsResponse</returns>
        System.Threading.Tasks.Task<CreateConfirmCustomizationDetailsResponse> ConfirmCustomizationDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmCustomizationDetailsResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateConfirmCustomizationDetailsResponse>> ConfirmCustomizationDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateAmazonMotorsResponse</returns>
        System.Threading.Tasks.Task<CreateAmazonMotorsResponse> CreateAmazonMotorsAsync (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateAmazonMotorsResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateAmazonMotorsResponse>> CreateAmazonMotorsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmDeliveryDetailsResponse</returns>
        System.Threading.Tasks.Task<CreateConfirmDeliveryDetailsResponse> CreateConfirmDeliveryDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmDeliveryDetailsResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateConfirmDeliveryDetailsResponse>> CreateConfirmDeliveryDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmOrderDetailsResponse</returns>
        System.Threading.Tasks.Task<CreateConfirmOrderDetailsResponse> CreateConfirmOrderDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmOrderDetailsResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateConfirmOrderDetailsResponse>> CreateConfirmOrderDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmServiceDetailsResponse</returns>
        System.Threading.Tasks.Task<CreateConfirmServiceDetailsResponse> CreateConfirmServiceDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmServiceDetailsResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateConfirmServiceDetailsResponse>> CreateConfirmServiceDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateDigitalAccessKeyResponse</returns>
        System.Threading.Tasks.Task<CreateDigitalAccessKeyResponse> CreateDigitalAccessKeyAsync (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateDigitalAccessKeyResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateDigitalAccessKeyResponse>> CreateDigitalAccessKeyAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateLegalDisclosureResponse</returns>
        System.Threading.Tasks.Task<CreateLegalDisclosureResponse> CreateLegalDisclosureAsync (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateLegalDisclosureResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateLegalDisclosureResponse>> CreateLegalDisclosureAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateUnexpectedProblemResponse</returns>
        System.Threading.Tasks.Task<CreateUnexpectedProblemResponse> CreateUnexpectedProblemAsync (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateUnexpectedProblemResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateUnexpectedProblemResponse>> CreateUnexpectedProblemAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateWarrantyResponse</returns>
        System.Threading.Tasks.Task<CreateWarrantyResponse> CreateWarrantyAsync (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateWarrantyResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<CreateWarrantyResponse>> CreateWarrantyAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of GetAttributesResponse</returns>
        System.Threading.Tasks.Task<GetAttributesResponse> GetAttributesAsync (string amazonOrderId, List<string> marketplaceIds);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of ApiResponse (GetAttributesResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<GetAttributesResponse>> GetAttributesAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of GetMessagingActionsForOrderResponse</returns>
        System.Threading.Tasks.Task<GetMessagingActionsForOrderResponse> GetMessagingActionsForOrderAsync (string amazonOrderId, List<string> marketplaceIds);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of ApiResponse (GetMessagingActionsForOrderResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<GetMessagingActionsForOrderResponse>> GetMessagingActionsForOrderAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds);
        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message providing the buyer an invoice
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of InvoiceResponse</returns>
        System.Threading.Tasks.Task<InvoiceResponse> SendInvoiceAsync (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body);

        /// <summary>
        /// 
        /// </summary>
        /// <remarks>
        /// Sends a message providing the buyer an invoice
        /// </remarks>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (InvoiceResponse)</returns>
        System.Threading.Tasks.Task<ApiResponse<InvoiceResponse>> SendInvoiceAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body);
        #endregion Asynchronous Operations
    }

    /// <summary>
    /// Represents a collection of functions to interact with the API endpoints
    /// </summary>
    public partial class MessagingApi : IMessagingApi
    {
        private software.amzn.spapi.Client.ExceptionFactory _exceptionFactory = (name, response) => null;

        /// <summary>
        /// Initializes a new instance of the <see cref="MessagingApi"/> class
        /// using Configuration object
        /// </summary>
        /// <param name="configuration">An instance of Configuration</param>
        /// <returns></returns>
        public MessagingApi(software.amzn.spapi.Client.Configuration configuration)
        {
            this.Configuration = configuration;
            ExceptionFactory = software.amzn.spapi.Client.Configuration.DefaultExceptionFactory;
        }

        IReadableConfiguration IApiAccessor.Configuration 
        {
            get => Configuration;  // Implicit upcast to interface
            set => Configuration = (software.amzn.spapi.Client.Configuration)value;
        }

        /// <summary>
        /// Gets the base path of the API client.
        /// </summary>
        /// <value>The base path</value>
        public String GetBasePath()
        {
            return this.Configuration.ApiClient.RestClient.Options.BaseUrl.ToString();
        }

        /// <summary>
        /// Sets the base path of the API client.
        /// </summary>
        /// <value>The base path</value>
        [Obsolete("SetBasePath is deprecated, please do 'Configuration.ApiClient = new ApiClient(\"http://new-path\")' instead.")]
        public void SetBasePath(String basePath)
        {
            // do nothing
        }

        /// <summary>
        /// Gets or sets the configuration object
        /// </summary>
        /// <value>An instance of the Configuration</value>
        public software.amzn.spapi.Client.Configuration Configuration {get; set;}

        /// <summary>
        /// Provides a factory method hook for the creation of exceptions.
        /// </summary>
        public software.amzn.spapi.Client.ExceptionFactory ExceptionFactory
        {
            get
            {
                if (_exceptionFactory != null && _exceptionFactory.GetInvocationList().Length > 1)
                {
                    throw new InvalidOperationException("Multicast delegate for ExceptionFactory is unsupported.");
                }
                return _exceptionFactory;
            }
            set { _exceptionFactory = value; }
        }

        /// <summary>
        /// Gets the default header.
        /// </summary>
        /// <returns>Dictionary of HTTP header</returns>
        [Obsolete("DefaultHeader is deprecated, please use Configuration.DefaultHeader instead.")]
        public IDictionary<String, String> DefaultHeader()
        {
            return new ReadOnlyDictionary<string, string>(this.Configuration.DefaultHeader);
        }

        /// <summary>
        /// Add default header.
        /// </summary>
        /// <param name="key">Header field name.</param>
        /// <param name="value">Header field value.</param>
        /// <returns></returns>
        [Obsolete("AddDefaultHeader is deprecated, please use Configuration.AddDefaultHeader instead.")]
        public void AddDefaultHeader(string key, string value)
        {
            this.Configuration.AddDefaultHeader(key, value);
        }

        /// <summary>
        ///  Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmCustomizationDetailsResponse</returns>
        public CreateConfirmCustomizationDetailsResponse ConfirmCustomizationDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body)
        {
             ApiResponse<CreateConfirmCustomizationDetailsResponse> localVarResponse = ConfirmCustomizationDetailsWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmCustomizationDetailsResponse</returns>
        public ApiResponse< CreateConfirmCustomizationDetailsResponse > ConfirmCustomizationDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->ConfirmCustomizationDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->ConfirmCustomizationDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->ConfirmCustomizationDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmCustomizationDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("ConfirmCustomizationDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmCustomizationDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmCustomizationDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmCustomizationDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmCustomizationDetailsResponse</returns>
        public async System.Threading.Tasks.Task<CreateConfirmCustomizationDetailsResponse> ConfirmCustomizationDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body)
        {
             ApiResponse<CreateConfirmCustomizationDetailsResponse> localVarResponse = await ConfirmCustomizationDetailsAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message asking a buyer to provide or verify customization details such as name spelling, images, initials, etc.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmCustomizationDetailsResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateConfirmCustomizationDetailsResponse>> ConfirmCustomizationDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmCustomizationDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->ConfirmCustomizationDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->ConfirmCustomizationDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->ConfirmCustomizationDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmCustomizationDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("ConfirmCustomizationDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmCustomizationDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmCustomizationDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmCustomizationDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateAmazonMotorsResponse</returns>
        public CreateAmazonMotorsResponse CreateAmazonMotors (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body)
        {
             ApiResponse<CreateAmazonMotorsResponse> localVarResponse = CreateAmazonMotorsWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateAmazonMotorsResponse</returns>
        public ApiResponse< CreateAmazonMotorsResponse > CreateAmazonMotorsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateAmazonMotors");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateAmazonMotors");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateAmazonMotors");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/amazonMotors";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateAmazonMotors", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateAmazonMotorsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateAmazonMotorsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateAmazonMotorsResponse)));
        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateAmazonMotorsResponse</returns>
        public async System.Threading.Tasks.Task<CreateAmazonMotorsResponse> CreateAmazonMotorsAsync (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body)
        {
             ApiResponse<CreateAmazonMotorsResponse> localVarResponse = await CreateAmazonMotorsAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about an Amazon Motors order. This message can only be sent by Amazon Motors sellers.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateAmazonMotorsResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateAmazonMotorsResponse>> CreateAmazonMotorsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateAmazonMotorsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateAmazonMotors");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateAmazonMotors");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateAmazonMotors");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/amazonMotors";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateAmazonMotors", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateAmazonMotorsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateAmazonMotorsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateAmazonMotorsResponse)));
        }

        /// <summary>
        ///  Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmDeliveryDetailsResponse</returns>
        public CreateConfirmDeliveryDetailsResponse CreateConfirmDeliveryDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body)
        {
             ApiResponse<CreateConfirmDeliveryDetailsResponse> localVarResponse = CreateConfirmDeliveryDetailsWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmDeliveryDetailsResponse</returns>
        public ApiResponse< CreateConfirmDeliveryDetailsResponse > CreateConfirmDeliveryDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateConfirmDeliveryDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateConfirmDeliveryDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateConfirmDeliveryDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmDeliveryDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateConfirmDeliveryDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmDeliveryDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmDeliveryDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmDeliveryDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmDeliveryDetailsResponse</returns>
        public async System.Threading.Tasks.Task<CreateConfirmDeliveryDetailsResponse> CreateConfirmDeliveryDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body)
        {
             ApiResponse<CreateConfirmDeliveryDetailsResponse> localVarResponse = await CreateConfirmDeliveryDetailsAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message to a buyer to arrange a delivery or to confirm contact information for making a delivery.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmDeliveryDetailsResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateConfirmDeliveryDetailsResponse>> CreateConfirmDeliveryDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmDeliveryDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateConfirmDeliveryDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateConfirmDeliveryDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateConfirmDeliveryDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmDeliveryDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateConfirmDeliveryDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmDeliveryDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmDeliveryDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmDeliveryDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmOrderDetailsResponse</returns>
        public CreateConfirmOrderDetailsResponse CreateConfirmOrderDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body)
        {
             ApiResponse<CreateConfirmOrderDetailsResponse> localVarResponse = CreateConfirmOrderDetailsWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmOrderDetailsResponse</returns>
        public ApiResponse< CreateConfirmOrderDetailsResponse > CreateConfirmOrderDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateConfirmOrderDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateConfirmOrderDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateConfirmOrderDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmOrderDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateConfirmOrderDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmOrderDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmOrderDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmOrderDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmOrderDetailsResponse</returns>
        public async System.Threading.Tasks.Task<CreateConfirmOrderDetailsResponse> CreateConfirmOrderDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body)
        {
             ApiResponse<CreateConfirmOrderDetailsResponse> localVarResponse = await CreateConfirmOrderDetailsAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message to ask a buyer an order-related question prior to shipping their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmOrderDetailsResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateConfirmOrderDetailsResponse>> CreateConfirmOrderDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmOrderDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateConfirmOrderDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateConfirmOrderDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateConfirmOrderDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmOrderDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateConfirmOrderDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmOrderDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmOrderDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmOrderDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateConfirmServiceDetailsResponse</returns>
        public CreateConfirmServiceDetailsResponse CreateConfirmServiceDetails (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body)
        {
             ApiResponse<CreateConfirmServiceDetailsResponse> localVarResponse = CreateConfirmServiceDetailsWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateConfirmServiceDetailsResponse</returns>
        public ApiResponse< CreateConfirmServiceDetailsResponse > CreateConfirmServiceDetailsWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateConfirmServiceDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateConfirmServiceDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateConfirmServiceDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmServiceDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateConfirmServiceDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmServiceDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmServiceDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmServiceDetailsResponse)));
        }

        /// <summary>
        ///  Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateConfirmServiceDetailsResponse</returns>
        public async System.Threading.Tasks.Task<CreateConfirmServiceDetailsResponse> CreateConfirmServiceDetailsAsync (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body)
        {
             ApiResponse<CreateConfirmServiceDetailsResponse> localVarResponse = await CreateConfirmServiceDetailsAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message to contact a Home Service customer to arrange a service call or to gather information prior to a service call.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateConfirmServiceDetailsResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateConfirmServiceDetailsResponse>> CreateConfirmServiceDetailsAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateConfirmServiceDetailsRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateConfirmServiceDetails");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateConfirmServiceDetails");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateConfirmServiceDetails");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/confirmServiceDetails";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateConfirmServiceDetails", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateConfirmServiceDetailsResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateConfirmServiceDetailsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateConfirmServiceDetailsResponse)));
        }

        /// <summary>
        ///  Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateDigitalAccessKeyResponse</returns>
        public CreateDigitalAccessKeyResponse CreateDigitalAccessKey (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body)
        {
             ApiResponse<CreateDigitalAccessKeyResponse> localVarResponse = CreateDigitalAccessKeyWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateDigitalAccessKeyResponse</returns>
        public ApiResponse< CreateDigitalAccessKeyResponse > CreateDigitalAccessKeyWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateDigitalAccessKey");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateDigitalAccessKey");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateDigitalAccessKey");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/digitalAccessKey";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateDigitalAccessKey", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateDigitalAccessKeyResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateDigitalAccessKeyResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateDigitalAccessKeyResponse)));
        }

        /// <summary>
        ///  Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateDigitalAccessKeyResponse</returns>
        public async System.Threading.Tasks.Task<CreateDigitalAccessKeyResponse> CreateDigitalAccessKeyAsync (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body)
        {
             ApiResponse<CreateDigitalAccessKeyResponse> localVarResponse = await CreateDigitalAccessKeyAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a buyer a message to share a digital access key that is required to utilize digital content in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateDigitalAccessKeyResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateDigitalAccessKeyResponse>> CreateDigitalAccessKeyAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateDigitalAccessKeyRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateDigitalAccessKey");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateDigitalAccessKey");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateDigitalAccessKey");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/digitalAccessKey";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateDigitalAccessKey", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateDigitalAccessKeyResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateDigitalAccessKeyResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateDigitalAccessKeyResponse)));
        }

        /// <summary>
        ///  Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateLegalDisclosureResponse</returns>
        public CreateLegalDisclosureResponse CreateLegalDisclosure (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body)
        {
             ApiResponse<CreateLegalDisclosureResponse> localVarResponse = CreateLegalDisclosureWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateLegalDisclosureResponse</returns>
        public ApiResponse< CreateLegalDisclosureResponse > CreateLegalDisclosureWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateLegalDisclosure");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateLegalDisclosure");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateLegalDisclosure");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateLegalDisclosure", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateLegalDisclosureResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateLegalDisclosureResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateLegalDisclosureResponse)));
        }

        /// <summary>
        ///  Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateLegalDisclosureResponse</returns>
        public async System.Threading.Tasks.Task<CreateLegalDisclosureResponse> CreateLegalDisclosureAsync (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body)
        {
             ApiResponse<CreateLegalDisclosureResponse> localVarResponse = await CreateLegalDisclosureAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a critical message that contains documents that a seller is legally obligated to provide to the buyer. This message should only be used to deliver documents that are required by law.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateLegalDisclosureResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateLegalDisclosureResponse>> CreateLegalDisclosureAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateLegalDisclosureRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateLegalDisclosure");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateLegalDisclosure");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateLegalDisclosure");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateLegalDisclosure", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateLegalDisclosureResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateLegalDisclosureResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateLegalDisclosureResponse)));
        }

        /// <summary>
        ///  Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateUnexpectedProblemResponse</returns>
        public CreateUnexpectedProblemResponse CreateUnexpectedProblem (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body)
        {
             ApiResponse<CreateUnexpectedProblemResponse> localVarResponse = CreateUnexpectedProblemWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateUnexpectedProblemResponse</returns>
        public ApiResponse< CreateUnexpectedProblemResponse > CreateUnexpectedProblemWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateUnexpectedProblem");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateUnexpectedProblem");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateUnexpectedProblem");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/unexpectedProblem";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateUnexpectedProblem", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateUnexpectedProblemResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateUnexpectedProblemResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateUnexpectedProblemResponse)));
        }

        /// <summary>
        ///  Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateUnexpectedProblemResponse</returns>
        public async System.Threading.Tasks.Task<CreateUnexpectedProblemResponse> CreateUnexpectedProblemAsync (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body)
        {
             ApiResponse<CreateUnexpectedProblemResponse> localVarResponse = await CreateUnexpectedProblemAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a critical message to a buyer that an unexpected problem was encountered affecting the completion of the order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateUnexpectedProblemResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateUnexpectedProblemResponse>> CreateUnexpectedProblemAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateUnexpectedProblemRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateUnexpectedProblem");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateUnexpectedProblem");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateUnexpectedProblem");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/unexpectedProblem";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateUnexpectedProblem", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateUnexpectedProblemResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateUnexpectedProblemResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateUnexpectedProblemResponse)));
        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>CreateWarrantyResponse</returns>
        public CreateWarrantyResponse CreateWarranty (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body)
        {
             ApiResponse<CreateWarrantyResponse> localVarResponse = CreateWarrantyWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of CreateWarrantyResponse</returns>
        public ApiResponse< CreateWarrantyResponse > CreateWarrantyWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateWarranty");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateWarranty");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateWarranty");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/warranty";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateWarranty", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateWarrantyResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateWarrantyResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateWarrantyResponse)));
        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of CreateWarrantyResponse</returns>
        public async System.Threading.Tasks.Task<CreateWarrantyResponse> CreateWarrantyAsync (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body)
        {
             ApiResponse<CreateWarrantyResponse> localVarResponse = await CreateWarrantyAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message to a buyer to provide details about warranty information on a purchase in their order.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (CreateWarrantyResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<CreateWarrantyResponse>> CreateWarrantyAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, CreateWarrantyRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->CreateWarranty");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->CreateWarranty");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->CreateWarranty");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/warranty";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("CreateWarranty", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<CreateWarrantyResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (CreateWarrantyResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(CreateWarrantyResponse)));
        }

        /// <summary>
        ///  Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>GetAttributesResponse</returns>
        public GetAttributesResponse GetAttributes (string amazonOrderId, List<string> marketplaceIds)
        {
             ApiResponse<GetAttributesResponse> localVarResponse = GetAttributesWithHttpInfo(amazonOrderId, marketplaceIds);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>ApiResponse of GetAttributesResponse</returns>
        public ApiResponse< GetAttributesResponse > GetAttributesWithHttpInfo (string amazonOrderId, List<string> marketplaceIds)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->GetAttributes");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->GetAttributes");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/attributes";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("GET"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("GetAttributes", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<GetAttributesResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (GetAttributesResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(GetAttributesResponse)));
        }

        /// <summary>
        ///  Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of GetAttributesResponse</returns>
        public async System.Threading.Tasks.Task<GetAttributesResponse> GetAttributesAsync (string amazonOrderId, List<string> marketplaceIds)
        {
             ApiResponse<GetAttributesResponse> localVarResponse = await GetAttributesAsyncWithHttpInfo(amazonOrderId, marketplaceIds);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Returns a response containing attributes related to an order. This includes buyer preferences.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of ApiResponse (GetAttributesResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<GetAttributesResponse>> GetAttributesAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->GetAttributes");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->GetAttributes");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/attributes";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("GET"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("GetAttributes", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<GetAttributesResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (GetAttributesResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(GetAttributesResponse)));
        }

        /// <summary>
        ///  Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>GetMessagingActionsForOrderResponse</returns>
        public GetMessagingActionsForOrderResponse GetMessagingActionsForOrder (string amazonOrderId, List<string> marketplaceIds)
        {
             ApiResponse<GetMessagingActionsForOrderResponse> localVarResponse = GetMessagingActionsForOrderWithHttpInfo(amazonOrderId, marketplaceIds);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>ApiResponse of GetMessagingActionsForOrderResponse</returns>
        public ApiResponse< GetMessagingActionsForOrderResponse > GetMessagingActionsForOrderWithHttpInfo (string amazonOrderId, List<string> marketplaceIds)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->GetMessagingActionsForOrder");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->GetMessagingActionsForOrder");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("GET"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("GetMessagingActionsForOrder", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<GetMessagingActionsForOrderResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (GetMessagingActionsForOrderResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(GetMessagingActionsForOrderResponse)));
        }

        /// <summary>
        ///  Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of GetMessagingActionsForOrderResponse</returns>
        public async System.Threading.Tasks.Task<GetMessagingActionsForOrderResponse> GetMessagingActionsForOrderAsync (string amazonOrderId, List<string> marketplaceIds)
        {
             ApiResponse<GetMessagingActionsForOrderResponse> localVarResponse = await GetMessagingActionsForOrderAsyncWithHttpInfo(amazonOrderId, marketplaceIds);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Returns a list of message types that are available for an order that you specify. A message type is represented by an actions object, which contains a path and query parameter(s). You can use the path and parameter(s) to call an operation that sends a message.  **Usage Plan:**  | Rate (requests per second) | Burst | | - -- - | - -- - | | 1 | 5 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header contains the usage plan rate limits for the operation, when available. The preceding table contains the default rate and burst values for this operation. Selling partners whose business demands require higher throughput might have higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This specifies the order for which you want a list of available message types.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <returns>Task of ApiResponse (GetMessagingActionsForOrderResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<GetMessagingActionsForOrderResponse>> GetMessagingActionsForOrderAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->GetMessagingActionsForOrder");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->GetMessagingActionsForOrder");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("GET"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("GetMessagingActionsForOrder", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<GetMessagingActionsForOrderResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (GetMessagingActionsForOrderResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(GetMessagingActionsForOrderResponse)));
        }

        /// <summary>
        ///  Sends a message providing the buyer an invoice
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>InvoiceResponse</returns>
        public InvoiceResponse SendInvoice (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body)
        {
             ApiResponse<InvoiceResponse> localVarResponse = SendInvoiceWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;
        }

        /// <summary>
        ///  Sends a message providing the buyer an invoice
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>ApiResponse of InvoiceResponse</returns>
        public ApiResponse< InvoiceResponse > SendInvoiceWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->SendInvoice");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->SendInvoice");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->SendInvoice");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/invoice";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) this.Configuration.ApiClient.CallApi(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);

            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("SendInvoice", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<InvoiceResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (InvoiceResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(InvoiceResponse)));
        }

        /// <summary>
        ///  Sends a message providing the buyer an invoice
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of InvoiceResponse</returns>
        public async System.Threading.Tasks.Task<InvoiceResponse> SendInvoiceAsync (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body)
        {
             ApiResponse<InvoiceResponse> localVarResponse = await SendInvoiceAsyncWithHttpInfo(amazonOrderId, marketplaceIds, body);
             return localVarResponse.Data;

        }

        /// <summary>
        ///  Sends a message providing the buyer an invoice
        /// </summary>
        /// <exception cref="software.amzn.spapi.Client.ApiException">Thrown when fails to make API call</exception>
        /// <param name="amazonOrderId">An Amazon order identifier. This identifies the order for which a message is sent.</param>
        /// <param name="marketplaceIds">A marketplace identifier. This identifies the marketplace in which the order was placed. You can only specify one marketplace.</param>
        /// <param name="body">This contains the message body for a message.</param>
        /// <returns>Task of ApiResponse (InvoiceResponse)</returns>
        public async System.Threading.Tasks.Task<ApiResponse<InvoiceResponse>> SendInvoiceAsyncWithHttpInfo (string amazonOrderId, List<string> marketplaceIds, InvoiceRequest body)
        {
            // verify the required parameter 'amazonOrderId' is set
            if (amazonOrderId == null)
                throw new ApiException(400, "Missing required parameter 'amazonOrderId' when calling MessagingApi->SendInvoice");
            // verify the required parameter 'marketplaceIds' is set
            if (marketplaceIds == null)
                throw new ApiException(400, "Missing required parameter 'marketplaceIds' when calling MessagingApi->SendInvoice");
            // verify the required parameter 'body' is set
            if (body == null)
                throw new ApiException(400, "Missing required parameter 'body' when calling MessagingApi->SendInvoice");

            var localVarPath = "/messaging/v1/orders/{amazonOrderId}/messages/invoice";
            var localVarPathParams = new Dictionary<String, String>();
            var localVarQueryParams = new List<KeyValuePair<String, String>>();
            var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
            var localVarFormParams = new Dictionary<String, String>();
            var localVarFileParams = new Dictionary<String, FileParameter>();
            Object localVarPostBody = null;

            // to determine the Content-Type header
            String[] localVarHttpContentTypes = new String[] {
                "application/json"
            };
            String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

            // to determine the Accept header
            String[] localVarHttpHeaderAccepts = new String[] {
                "application/hal+json"
            };
            String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
            if (localVarHttpHeaderAccept != null)
                localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

            if (amazonOrderId != null) localVarPathParams.Add("amazonOrderId", this.Configuration.ApiClient.ParameterToString(amazonOrderId)); // path parameter
            if (marketplaceIds != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "marketplaceIds", marketplaceIds)); // query parameter
            if (body != null && body.GetType() != typeof(byte[]))
            {
                localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter
            }
            else
            {
                localVarPostBody = body; // byte array
            }


            // make the HTTP request
            RestResponse localVarResponse = (RestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, ChangeHttpMethod("POST"), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType);
            int localVarStatusCode = (int) localVarResponse.StatusCode;

            if (ExceptionFactory != null)
            {
                Exception exception = ExceptionFactory("SendInvoice", localVarResponse);
                if (exception != null) throw exception;
            }

            return new ApiResponse<InvoiceResponse>(localVarResponse.StatusCode,
                ConvertHeadersToMultimap(localVarResponse),
                (InvoiceResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(InvoiceResponse)));
        }


        public class Builder
        {
            private LWAAuthorizationCredentials lwaAuthorizationCredentials;
            private RateLimitConfiguration rateLimitConfiguration;

            public Builder SetLWAAuthorizationCredentials(LWAAuthorizationCredentials lwaAuthorizationCredentials)
            {
                this.lwaAuthorizationCredentials = lwaAuthorizationCredentials;
                return this;
            }
            
            
            public Builder SetRateLimitConfiguration(RateLimitConfiguration rateLimitConfiguration)
            {
                this.rateLimitConfiguration = rateLimitConfiguration;
                return this;
            }

            public MessagingApi Build() 
            {
                if (lwaAuthorizationCredentials == null) 
                {
                    throw new NullReferenceException("LWAAuthoriztionCredentials not set");
                }

                
                software.amzn.spapi.Client.Configuration configuration = new software.amzn.spapi.Client.Configuration()
                {
                    AuthorizationCredentials = lwaAuthorizationCredentials,
                    RateLimitConfig = rateLimitConfiguration
                };

                // default HTTP connection timeout (in milliseconds)
                configuration.initializeApiClient();
                configuration.Timeout = 100000;

                return new MessagingApi(configuration);
            }
        }
        
        private static Multimap<string, string> ConvertHeadersToMultimap(RestResponse response)
        {
            var multimap = new Multimap<string, string>();
            foreach (var header in response.Headers)
            {
                multimap.Add(header.Name, header.Value?.ToString());
            }
            return multimap;
        }


        private static RestSharp.Method ChangeHttpMethod(String httpMethod) {
            switch(httpMethod) {
                case "GET":
                    // GET logic
                    return Method.Get;
                case "POST":
                    // POST logic
                    return Method.Post;
                case "DELETE":
                    return Method.Delete;
                case "PUT":
                    return Method.Put;
                case "PATCH":
                    return Method.Patch;
                case "OPTIONS":
                    return Method.Options;
            }
            return Method.Head;
        }

    }
}
